#pragma once

#include "ZNetworkCommon.h"
#include "ZPoolObject.h"

namespace	Z	{

//------------------------------------------------------------------------------------------------------------------------
struct	MessageHandler;

class	NetworkMessage
	:	public PoolObject
{
public:
	NetworkMessage(NetworkId kNetworkId)	:	mNetworkId(kNetworkId)	{}
	virtual	~NetworkMessage()	{}
	NetworkId	getNetworkId()	const	{	return mNetworkId;		}
	virtual	void	pump(MessageHandler& kMessageHandler)	= 0;
	virtual	byte_t*	data()	const	{	return 0;	}
	virtual	size_t	size()	const	{	return 0;	}

private:
	NetworkId	mNetworkId;
};

}